package com.springcloud.enums;

import java.util.HashMap;
import java.util.Map;

public enum OperateType {
    IMPORT("E"),
    EXPORT("A"),
    XPORT("X");
    private static final Map<String, OperateType> map;

    static {
        map = new HashMap<>();
        for (OperateType type : OperateType.values()) {
            map.put(type.code, type);
        }
    }

    private final String code;

    OperateType(String code) {
        this.code = code;
    }

    public static boolean contain(String code) {
        return map.containsKey(code);
    }


}
